Release 10.1A: OpenEdge Application Server:
Developing AppServer Applications
Using code editors
For any persistent procedures that you write by hand, you can also use the ProtoGen utility to generate include files from any super procedure prototypes you might need. However, you might prefer or need to code these prototypes by hand, especially in a character environment.
To code the necessary prototypes, edit a persistent procedure that requires them and include a
PROCEDUREstatement for each internal procedure prototype and aFUNCTIONstatement for each user-defined function prototype using theINSUPERoption in each case. For internal procedures, you must also follow thePROCEDUREstatement with anyDEFINEPARAMETERstatements to specify the parameters for the internal procedure and terminate the procedure block with anENDstatement, like a standard procedure block. For user-defined functions, you can include the parameter and return value prototypes within theFUNCTIONstatement itself:
This example defines prototypes for an internal procedure,
addMessage, and a user-defined function,setPosition, that are defined in some super procedure. Note that there is no indication of what super procedure these prototypes refer to. For the Open Client Toolkit, only the prototypes are required; theINSUPERoption only tells OpenEdge that the procedure or function definition lies elsewhere. As long as the toolkit knows the prototypes, it can generate the correct proxy object definitions. OpenEdge then locates the appropriate code to execute at run time for each super procedure prototype that the Open Client application references.Again, remember to compile and generate the r-code for each persistent procedure before making it available for access by the Open Client Toolkit.
|
Copyright © 2005 Progress Software Corporation www.progress.com Voice: (781) 280-4000 Fax: (781) 280-4095 |